package routers

import (
	"ABlog/controllers"
	"github.com/astaxie/beego"
)

func init() {
	beego.Router("/", &controllers.MainController{})
	beego.Router("/edit", &controllers.EditArticleController{})
	beego.Router("/edit/:id", &controllers.EditArticleController{})
	beego.Router("/article/:id", &controllers.GetArticleController{})

	beego.Router("/api/save", &controllers.ApiSaveArticleController{})
	beego.Router("/api/add_to_index", &controllers.ApiAddToIndexArticleController{})
	beego.Router("/api/upload", &controllers.ApiUploadFileController{})
}
